Remove dependency on lib*gif!!!!
authorJonathan Blandford <jrb@redhat.com>
Wed, 3 Nov 1999 22:27:59 +0000 (22:27 +0000)
committerJonathan Blandford <jrb@src.gnome.org>
Wed, 3 Nov 1999 22:27:59 +0000 (22:27 +0000)
1999-11-03  Jonathan Blandford  <jrb@redhat.com>

* src/Makefile.am (libpixbuf_gif_la_LIBADD): Remove dependency on
lib*gif!!!!

Also, some code cleanups to io-gif

gdk-pixbuf/ChangeLog
gdk-pixbuf/Makefile.am
gdk-pixbuf/io-gif.c

index 599fd77b10fd940ca1d1a555da6714d838dbe5c4..2235588b160b3706ee21798aac37fa0467520eb3 100644 (file)
@@ -1,3 +1,8 @@
+1999-11-03  Jonathan Blandford  <jrb@redhat.com>
+
+       * src/Makefile.am (libpixbuf_gif_la_LIBADD): Remove dependency on
+       lib*gif!!!!
+
 1999-11-03  Michael Fulbright  <msf@redhat.com>
 
        * src/io-jpeg.c (image_load_increment): Further removal of
index 63fdd512b645f1166c4969c06acd6cd2612284ed..aab49a551e03f5386c4daf8fdc1c3bdc843702d0 100644 (file)
@@ -87,7 +87,7 @@ libpixbuf_xpm_la_LDFLAGS = -avoid-version -module
 #
 libpixbuf_gif_la_SOURCES = io-gif.c
 libpixbuf_gif_la_LDFLAGS = -avoid-version -module
-libpixbuf_gif_la_LIBADD = $(LIBGIF)
+libpixbuf_gif_la_LIBADD =
 
 #
 # The TIFF loader
index 80a6c9718905fca6801d7b8db5175a4ba804a072..630672f7b90c2091a1390790409b71733da4591b 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Authors: Jonathan Blandford <jrb@redhat.com>
  *          Adapted from the gimp gif filter written by Adam Moss <adam@gimp.org>
- *          Gimp work based on earlier work by ......
+ *          Gimp work based on earlier work.
  *          Permission to relicense under the LGPL obtained.
  *
  * This library is free software; you can redistribute it and/or
 
 
 #define MAXCOLORMAPSIZE  256
-
-#define CM_RED           0
-#define CM_GREEN         1
-#define CM_BLUE          2
-
 #define MAX_LZW_BITS     12
 
 #define INTERLACE          0x40
 #define BitSet(byte, bit)  (((byte) & (bit)) == (bit))
 #define LM_to_uint(a,b)         (((b)<<8)|(a))
 
-#define GRAYSCALE        1
-#define COLOR            2
-
 typedef unsigned char CMap[3][MAXCOLORMAPSIZE];
 
-
 /* Possible states we can be in. */
 enum {
        GIF_START,
@@ -72,9 +63,6 @@ typedef struct _Gif89 Gif89;
 struct _Gif89
 {
        int transparent;
-       int delay_time;
-       int input_flag;
-       int disposal;
 };
 
 typedef struct _GifContext GifContext;
@@ -88,7 +76,6 @@ struct _GifContext
        unsigned int color_resolution;
        unsigned int background;
        unsigned int aspect_ratio;
-       int gray_scale;
        GdkPixbuf *pixbuf;
        Gif89 gif89;
 
@@ -248,16 +235,14 @@ gif_get_colormap (GifContext *context)
                        return -1;
                }
 
-               context->color_map[CM_RED][context->colormap_index] = rgb[0];
-               context->color_map[CM_GREEN][context->colormap_index] = rgb[1];
-               context->color_map[CM_BLUE][context->colormap_index] = rgb[2];
+               context->color_map[0][context->colormap_index] = rgb[0];
+               context->color_map[1][context->colormap_index] = rgb[1];
+               context->color_map[2][context->colormap_index] = rgb[2];
 
                context->colormap_flag &= (rgb[0] == rgb[1] && rgb[1] == rgb[2]);
                context->colormap_index ++;
        }
 
-       context->gray_scale = (context->colormap_flag) ? GRAYSCALE : COLOR;
-
        return 0;
 }
 
@@ -327,9 +312,6 @@ gif_get_extension (GifContext *context)
                        retval = get_data_block (context, (unsigned char *) context->block_buf, NULL);
                        if (retval != 0)
                                return retval;
-                       context->gif89.disposal = (context->block_buf[0] >> 2) & 0x7;
-                       context->gif89.input_flag = (context->block_buf[0] >> 1) & 0x1;
-                       context->gif89.delay_time = LM_to_uint (context->block_buf[1], context->block_buf[2]);
                        if (context->pixbuf == NULL) {
                                /* I only want to set the transparency if I haven't
                                 * created the pixbuf yet. */